from typing import Optional

import PySide6.QtCore
import PySide6.QtWidgets
from PySide6.QtCore import QSize, Qt
from PySide6.QtWidgets import QToolBar

from ....PSData import PSData, PSDataServer


class LeftToolBar(QToolBar, PSDataServer):
    def __init__(self, parent: Optional[PySide6.QtWidgets.QWidget] = ...):
        super().__init__(parent=parent)
        self.setAllowedAreas(Qt.LeftToolBarArea)
        self.setFloatable(False)
        self.setMovable(False)
        self.setIconSize(QSize(40, 40))
